<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8" />
	<link rel="stylesheet" href="css/form.css" />
</head>

<body>
	<div id="header-wrap" data-mn="0">
		<a href="###" data-link="safe" data-type="ico" class="left ico-m ico-left"></a>
		<h2>修改密码</h2>
	</div>
	<div class="" id="">
		<div class="tips">
			<div class="t-info">请输入原密码</div>
			<div class="t-error"></div>
		</div>
		<form>
		<ul class="form-list">
			<li class="ico-m ico-pl ico-lock" data-type="ico">
				<div class="fl-cont form-input f-right-ico">
					<input type="password" id="pw" placeholder="请原密码" />
					<a href="###"  data-type="ico" class="check-pw ico-m ico-eye" ></a>
				</div>
			</li>
		</ul>
		<div class="">
			<a href="###" data-link="edit-pw-2" class="btn b-red"><span id="check">确认</span></a>
		</div>
		</form>
		
	</div>
	<script>
	$(function(){
		$(".check-pw").hover(
			function(){$(this).siblings("input").attr("type","text")},
			function(){$(this).siblings("input").attr("type","password")}
		)
		$("#check").on("click",function(){
			var old_pw = $.cookie("user_pw");
			var pw = $("#pw").val()
			if(pw !== old_pw){
				$(".t-error").text("原始密码错误").fadeIn(100)
				$(".t-info").hide()
				reset_tip()
				return false
			}
		
		})
	})
	</script>	
</body>

</html>
